from django.urls import path
from rest_framework import routers
from . import views
from dvadmin.knowledge.views import KnowledgeViewSet
from dvadmin.knowledge.views import KnowledgeRecordViewSet
from dvadmin.knowledge.views import KnowledgeHitViewSet
from dvadmin.knowledge.views import KGChatView,ChatView,ChatCallView,ChatRAG

knowledge_url = routers.SimpleRouter()

knowledge_url.register(r'knowledge_list', KnowledgeViewSet)
knowledge_url.register(r'knowledgerecord_list', KnowledgeRecordViewSet)
knowledge_url.register(r'hit', KnowledgeHitViewSet)


urlpatterns = [
    path('kgchat/', KGChatView.as_view(), name='kgchat'),
    path('chatAgent/', ChatView.as_view(), name='chat'),
    path('chatCall/', ChatCallView.as_view(), name='chatcall'),    
    path('chatrag/', ChatRAG.as_view(), name='chatrag')
]

urlpatterns += knowledge_url.urls